package com.emergency.db.domain.item;

import com.emergency.base.domain.BaseEntity;

import javax.persistence.*;
import java.math.BigDecimal;

//装备位置表
@Entity
@Table(name = "bas_item_location")
public class ItemLocation extends BaseEntity {

    private BigDecimal longitude; //经度、

    private BigDecimal latitude;//纬度

    @OneToOne(targetEntity = Item.class, fetch = FetchType.LAZY)
    @JoinColumn(name = "item_id", referencedColumnName = "id")
    private Item item;

    public BigDecimal getLongitude() {
        return longitude;
    }

    public void setLongitude(BigDecimal longitude) {
        this.longitude = longitude;
    }

    public BigDecimal getLatitude() {
        return latitude;
    }

    public void setLatitude(BigDecimal latitude) {
        this.latitude = latitude;
    }

    public Item getItem() {
        return item;
    }

    public void setItem(Item item) {
        this.item = item;
    }
}
